<%= form_with(model: post) do |form| %>
  <% if post.errors.any? %>
    <div id="error_explanation">
      <h2><%= pluralize(post.errors.count, "error") %> prohibited this post from being saved:</h2>

      <ul>
        <% post.errors.full_messages.each do |message| %>
          <li><%= message %></li>
        <% end %>
      </ul>
    </div>
  <% end %>

  <div>
    <%= form.label :content, style: "display:block" %>
    <%= form.text_area :content, cols: 80, rows: 42 %>
  </div>

  <div class="actions">
    <%= form.submit %>
  </div>
<% end %>
